package com.example.orderserver.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;

/**
 * @author benjamin_5
 * @Description
 * @date 2023/3/8
 */
@FeignClient(name = "product-server", url = "localhost:8080", contextId = "product-server-ip")
public interface ProductFeign {

    String PREFIX = "product";
    String GET_INFO = PREFIX + "/getInfo";
    String GET_BY_NAME = PREFIX + "/getByName";

    @GetMapping(GET_INFO)
    String getInfo();

    @GetMapping(GET_BY_NAME)
    String getByName(String name);

}
